#!/usr/bin/env bash
module=$1
profile=$2

case x$module in
    "xportal-admin")
        case $profile in
		      test|demo|yizu|prod)
		          git pull
 		          mvn -P$profile clean package tomcat7:redeploy -pl kylin-$module -DskipTests
        	    echo "deploy success!"
          	  exit
			         ;;
             *)
                ;;
        esac
	;;
    *)
    ;;
esac

echo "deploy [portal-admin ]  [test | demo | yizu| prod]"
exit 1
